package lengxf;

import com.mysql.cj.jdbc.MysqlDataSource;

import javax.sql.DataSource;

public class BlogDataSourceFactory {
  public static DataSource getBlogDataSource() {
    MysqlDataSource mysqlDataSource = new MysqlDataSource();
    mysqlDataSource.setURL("jdbc:mysql://localhost:3306/test_1");
    mysqlDataSource.setUser("root");
    mysqlDataSource.setPassword("123456");
    return mysqlDataSource;
  }
}
